| Fully Qualified Name: | CodeIgniter\HTTP\UserAgent |
Abstraction for an HTTP user agent
| Name | Description | Defined By |
|---|---|---|
| __construct() | Constructor | UserAgent |
| __toString() | Outputs the original Agent String when cast as a string. | UserAgent |
| getAgentString() | Agent String | UserAgent |
| getBrowser() | Get Browser Name | UserAgent |
| getMobile() | Get the Mobile Device | UserAgent |
| getPlatform() | Get Platform | UserAgent |
| getReferrer() | Get the referrer | UserAgent |
| getRobot() | Get The Robot Name | UserAgent |
| getVersion() | Get the Browser Version | UserAgent |
| isBrowser() | Is Browser | UserAgent |
| isMobile() | Is Mobile | UserAgent |
| isReferral() | Is this a referral from another site? | UserAgent |
| isRobot() | Is Robot | UserAgent |
| parse() | Parse a custom user-agent string | UserAgent |
Constructor
Sets the User Agent and runs the compilation routine
| Parameter Name | Type | Description |
|---|---|---|
| $config | null |
Returns:
Outputs the original Agent String when cast as a string.
Returns: string
Agent String
Returns: string
Get Browser Name
Returns: string
Get the Mobile Device
Returns: string
Get Platform
Returns: string
Get the referrer
Returns: string
Get The Robot Name
Returns: string
Get the Browser Version
Returns: string
Is Browser
| Parameter Name | Type | Description |
|---|---|---|
| $key | string |
Returns: bool
Is Mobile
| Parameter Name | Type | Description |
|---|---|---|
| $key | string |
Returns: bool
Is this a referral from another site?
Returns: bool
Is Robot
| Parameter Name | Type | Description |
|---|---|---|
| $key | string |
Returns: bool
Parse a custom user-agent string
| Parameter Name | Type | Description |
|---|---|---|
| $string | string |
Returns: void